package com.bdd.mapper;


import com.bdd.entity.Discount;
import com.bdd.model.bo.DiscountBO;
import com.github.pagehelper.Page;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface DiscountDao {
    int deleteByPrimaryKey(Integer id);

    int insert(Discount record);

    int insertSelective(Discount record);

    Discount selectByPromotionName(String promotionName);

    Discount selectByPrimaryKey(Integer id);

    Discount selectByName(String name);

    List<Discount> selectAll();

    Page<DiscountBO> selectBOList();

    Discount selectDiscounts(String discounts);

    List<DiscountBO> selectBOListByName(@Param("name")String name);

    int updateByPrimaryKeySelective(Discount record);

    int updateByPrimaryKey(Discount record);
}